<?php
namespace app\validate;

use think\Validate;

class AdminUser extends Validate
{
    protected $rule = [
        'username' =>  'require|max:25',
        'password' =>  'require|max:255',
        'nickname' =>  'require|max:25'
    ];

    protected $message  =   [
        'username.require' => '账号必须填写！',
        'username.max'     => '账号的字数不正确！',
        'password.require' => '密码必须填写！',
        'password.max'     => '密码的字数不正确！',
        'nickname.require' => '昵称必须填写！',
        'nickname.max'     => '昵称的字数不正确！'
    ];

}